package Observer.Simple;

import java.util.ArrayList;
import java.util.List;

public abstract class AbstractSubject {
    protected List<IObserver> observers;

    public AbstractSubject()
    {
        observers = new ArrayList<IObserver>();
    }

    public void add(IObserver observer)
    {
        observers.add(observer);
    }

    public void remove(IObserver observer)
    {
        observers.remove(observer);
    }

    public abstract void notifyObserver();

}
